package com.eighth.factory.simple;

/**
 * Author Name: Justice
 * Project Name: Stage11
 * File Name: PhoneFactory
 * Package Name: com.eighth.factory.simple
 * Date: 2020-03-27 13:52
 * Copyright (c) 2020,All Rights Reserved.
 */


class PhoneFactory {
    Phone makePhone(String phoneType) {
        if (phoneType.equalsIgnoreCase("MiPhone")) {
            return new MiPhone();
        } else if (phoneType.equalsIgnoreCase("IPhone")) {
            return new IPhone();
        }
        return null;
    }
}
